home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 May: Tool Chest / Developer CD Series May 1996 (Tool Chest) (Apple Computer) (1996).iso / Tool Chest / Development Tools & Languages / Dylan Related / Thomas / MacGambit⁄Thomas / MacGambit⁄Thomas Sources / Thomas 1.1 sources / patches.scm < prev    next >
Encoding:
Text File  |  1995-03-15  |  1.6 KB  |  46 lines  |  [TEXT/gamI]

  1. ;;;from run-methods.scm
  2. (define dylan:expt (dylan::generic-fn 'expt two-numbers expt))
  3.  
  4.  
  5. ;;;from compiler.scm
  6. (define (thomas file-name . expressions)
  7.   (compile-expression `(BEGIN ,@expressions) #F thomas-rep-module-variables
  8.     (lambda (new-vars preamble-code compiled)
  9.       new-vars                          ; Not used
  10.       (with-output-to-file file-name
  11.         (lambda ()
  12.           (display "; Output generated by the CRL Thomas->Scheme compiler.")
  13.           (newline)
  14.           (implementation-specific:generate-file
  15.            expressions
  16.            `(begin
  17.               ,@preamble-code
  18.               (dylan::catch-all-conditions
  19.                (lambda () ,compiled))
  20.               (set! thomas-rep-module-variables
  21.                     (append ',new-vars thomas-rep-module-variables))
  22.               )))))))
  23.  
  24. ;;from implementation-specific.scm
  25. (define make-condition (lambda (x y) (cons x y))) ;let 'em have the args
  26.  
  27.            ;fix ##newline call to supply out (required)
  28. (define (implementation-specific:enter-debugger dylan-condition)
  29.   ;; implementation-specific:enter-debugger is only called by `break',
  30.   ;; so I label the ##debug-repl with "*** Breakpoint".
  31.   ;; Printing the arguments to `break':
  32.   (##call-with-current-continuation
  33.     (lambda (cont)
  34.       (##sequentially
  35.         (lambda ()
  36.           (let ((out (##repl-out)))
  37.             (##newline out)
  38.             (##write-string
  39.              (dylan-call dylan:condition-format-string dylan-condition)
  40.              out)
  41.             (##newline out)
  42.             (##newline out)
  43.             (##write-string "*** Breakpoint" out)
  44.             (##newline out)
  45.             (##debug-repl cont)))))))
  46.